package com.ruoyi.system.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;

/**
 * 购物车对象 p_store_cart
 *
 * @author ruoyi
 * @date 2022-08-01
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("p_store_cart")
public class PStoreCart extends BaseEntity {

    private static final long serialVersionUID=1L;

    /**
     * 购物车表ID
     */
    @TableId(value = "id")
    private Long id;
    /**
     * 用户ID
     */
    private Long uid;
    /**
     * 类型
     */
    private String type;
    /**
     * 商品ID
     */
    private Long productId;
    /**
     * 商品属性
     */
    private String productAttrUnique;
    /**
     * 商品数量
     */
    private Integer cartNum;
    /**
     * 是否为立即购买
     */
    private Integer isNew;
    /**
     * 拼团id
     */
    private Long combinationId;
    /**
     * 秒杀商品ID
     */
    private Long seckillId;
    /**
     * 砍价id
     */
    private Long bargainId;
    /**
     * 购物车状态
     */
    private Integer status;

    /**
     * 删除标志（0代表存在 2代表删除）
     */
    @TableLogic
    private String delFlag;

    @TableField(exist = false)
    private String image;

    @TableField(exist = false)
    private String imageId;

    @TableField(exist = false)
    private String storeName;

    @TableField(exist = false)
    private String storeInfo;

    /**
     * 商品价格
     */
    @TableField(exist = false)
    private BigDecimal price;

    /**
     * 邮费
     */
    @TableField(exist = false)
    private BigDecimal postage;

    /**
     * 前台用
     */
    @TableField(exist = false)
    private Boolean isBuySelect = false;

    /**
     * 前台用
     */
    @TableField(exist = false)
    private Boolean isDelSelect = false;
}
